﻿using Shop.Model.DB;
using Shop.Model.GoodsSku;
using Shop.RemoteModel.GoodsSku.Model;
using WeDonekRpc.Model;

namespace Shop.Repository
{
    public interface IGoodsSkuRepository : IShopBaseRepository<DBGoodsSku, long>
    {
        SkuDatum[] Query (SkuQueryParam query, IBasicPage paging, out int count);
        DBGoodsSku[] GetsByGoodsId (long goodsId);
        DBGoodsSku Find (long goodsId, string specKey);
        Result[] GetsByGoodsId<Result> (long goodsId) where Result : class, new();
        Result[] GetsByGoodsId<Result> (long[] goodsId) where Result : class, new();
        long Add (SkuAdd add);
        bool Set (DBGoodsSku sku, SkuSet set);
        SkuDatum[] GetSkuDatums (long[] ids);
    }
}